<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
    <%@ page isELIgnored="false" %>
<%@taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>Insert title here</title>
</head>
<body>
<h1>商品列表</h1>
<<<<<<< HEAD
<img src="img/cart.bmp" onclick="location.href='/estore/cart.jsp';" style="cursor: pointer;"/><br/>
=======
<img src="img/cart.bmp" onclick="location.href='/estore/cart.jsp';" style="cursor: pointer;"/><br/>
>>>>>>> 6b4b1ef394866621273986912121e188b00bfac5
<hr/>
<!-- 遍历 List  -->
<c:if test="${empty products}">
	<h1>系统还没有添加任何商品！</h1>
</c:if>
<c:if test="${not empty products}">
	<!-- 用分隔线分隔 -->
	<c:forEach items="${products}" var="product">
		商品编号 ${product.id }<br/>
		<h2><a href="/estore/ShowProductServlet?id=${product.id }">商品名称 ${product.name }</a></h2>
		<h3>商品分类 ${product.category }</h3>
		<img src="${product.img }" onclick="location.href='/estore/ShowProductServlet?id=${product.id }';" style="cursor: pointer;"/><br/>
		<h3 style="color:red;font-weight: bold">价格 ： ${product.price }</h3>
		<hr/>
	</c:forEach>
</c:if>
</body>
</html>